package com.rightsidetech.activity.mapper;

import com.rightsidetech.activity.entity.ActCouponUsedRecord;
import org.apache.ibatis.annotations.Param;

public interface ActCouponUsedRecordMapper {
    int deleteByPrimaryKey(Long id);

    int insert(ActCouponUsedRecord record);

    int insertSelective(ActCouponUsedRecord record);

    ActCouponUsedRecord selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(ActCouponUsedRecord record);

    int updateByPrimaryKey(ActCouponUsedRecord record);

    int selectCountByActivityIdAndStoreId(@Param("activityId")Long activityId,@Param("storeId") Long storeId);

    //查询该活动用户是否已经使用过优惠券
    int selectCountByUserInfoIdAndActivityIdAndStatus(@Param("activityId") Long activityId, @Param("userInfoId") Long userInfoId);
}